import pandas as pd
from numpy import *
import numpy as np

def readFlie(path):    #读取一个样本的记录，默认一个文件一条样本
    with open(path,'r',errors='ignore') as file:
        content = file.read()
        file.close()
        return content

def readList(path):    #读取一个csv，输出样本列表，元素形式[{"title"}...]
    data = pd.read_csv(path,encoding='utf-8')
    col = data["标题"]
    sample_list = np.array(col)
    return sample_list



main = readList('.\\total\\地区级\\city.csv')[:10]

print(main)